package cn.fudong.bos.dao.base;

import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;

import org.springframework.data.jpa.repository.Modifying;
import org.springframework.data.jpa.repository.Query;
import org.springframework.stereotype.Repository;

import cn.fudong.bos.domain.base.Courier;

@Repository
public interface CourierRepository extends JpaRepository<Courier, Integer>, JpaSpecificationExecutor<Courier> {
	
	//批量作废
	@Query(value = "update Courier set deltag='1' where id = ?")
	@Modifying
	public void delBatch(Integer id);
	
	//批量还原
	@Query(value = "update Courier set deltag=null where id = ?")
	@Modifying
	public void RestoreBatch(Integer id);

}
